from time import sleep
from selenium import webdriver
# 准备配置
mobileEmulation = {'deviceName': 'iPhone SE'}
# 创建options对象
options = webdriver.ChromeOptions()
# 添加配置选项信息
options.add_experimental_option('mobileEmulation', mobileEmulation)
# 打开浏览器
driver = webdriver.Chrome(options=options)
# 输入网址
driver.get('https://www.so.com')
# 关闭浏览器
sleep(3)
driver.quit()
